*{
    margin: 0;
    padding: 0;
}
html, body,h1, h2, h3, h4, h5, h6, .h1, .h2, .h3, .h4, .h5, .h6, *{
    font-family: NotoSansHans-Regular,AvenirNext-Regular,arial,Hiragino Sans GB,"Microsoft Yahei","Hiragino Sans GB","WenQuanYi Micro Hei",sans-serif;
}
body{
    display: flex;
}
#preview{
    margin: 0 auto;
    height: 100%;
    text-align: center;
    position: relative;
    flex: 1;
    background-color: #111;
    overflow: hidden;
}
#preview.drawable{
    cursor: crosshair;
}
#canvas{
    transition: transform 0.4s ease-in-out;
    position: relative;
    left: 0;
    right:0;
}
#canvas > img {
    margin: 0 auto;
    height: 100%;
    max-width: 100%;
    object-fit: contain;
}
#position-number{
    width: 80px;
    height: 25px;
    border: 1px solid #b3b3b3;
    background-color: #000000;
    border-radius: 3px;
    box-sizing: border-box;
    text-align: center;
    line-height: 25px;
    position: absolute;
    top: 20px;
    left: 20px;
    z-index: 100;
    display: none;
}
#position-number #number{
    font-size: 12px;
    color: #ffffff;
}
#overlay{
    position: absolute;
    left: 0;
    right: 0;
    top: 0;
    bottom: 0;
    z-index: 2;
    cursor: default;
}
#overlay.drawable{
    cursor: crosshair;
}
#overlay.movable{
    cursor: grab;
    cursor: -moz-grab;
    cursor: -webkit-grab;
}
#overlay.movable:active{
    cursor: grabbing;
    cursor: -moz-grabbing;
    cursor: -webkit-grabbing;
}

#overlay > .shape{
    overflow: visible;
    position: absolute;
    cursor: move;
    user-select: none;
}
#overlay > .shape.forefront{
    z-index: 9999 !important;
}
#overlay > .shape > line
{
    stroke:crimson;
    stroke-width:1;
    fill:transparent;
}
#overlay > .shape > line.side{
    stroke: gray;
}
#overlay > .shape > line.back{
    stroke:gray;
    stroke-dasharray:2,2
}
#overlay > .shape.selected > line{
    stroke: #8edc21;
}
#overlay > .shape.active > line{
    stroke: #dbdc7e;
}
#overlay > .shape path{
    fill: rgba(255, 161, 48, 0.1);
}
#overlay:not(.drawable) > .shape:hover path{
    fill:rgba(255, 255, 255, 0.2);
}
#overlay > .shape.selected path{
    fill: rgba(142, 220, 33, 0.3);
}

#overlay.movable > .shape,
#overlay.drawable > .shape{
    pointer-events: none;
}
#overlay.drawable > .shape.drawing{
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
}
#overlay > .shape .circle{
    r:3;
    fill: #ffe9bd;
}
#overlay > .shape circle.control{
    r:3;
    fill:black;
}
#overlay > .shape line.control{
    stroke:rgb(99,99,99);
    stroke-width:1
}
#overlay.drawable > .shape .circle{
    pointer-events: none;
}


#result{
    width: 200px;
    flex: none;
    height: 100%;
    position: relative;
    text-align: center;
    background-color: #eee;
    display: flex;
    flex-direction: column;
}
#result-header{
    flex: none;
    height: 30px;
    background-color: black;
    color: gainsboro;
    text-align: center;
    font-size: 14px;
    line-height: 30px;
}
#result-list{
    flex: 1;
    list-style: none;
    overflow-x:hidden;
    overflow-y:auto;
}
#result-list::-webkit-scrollbar {
    width: 5px;
}
#result-list > li{
    width: 100%;
    height: 35px;
    position: relative;
}
#result-list > li select{
    width: 190px;
}
#result-list > li .select2-container
{
    height: 30px;
    border: 1px dashed #ccc;
    margin: 5px;
    outline: none;
    font-size: 12px;
    text-align: left;
}
#result-list > li .select2-selection{
    border: 0;
    outline: none;
}

/**********************
*
*  Select2样式调整
*
***********************/
.select-input{
    border: 1px dashed #ccc;
    padding: 0 0 0 10px;
    height: 32px;
    display: block;
    outline: none;
    position: absolute;
    width: 190px;
    top: 5px;
    left: 5px;
}
.select-input.hidden{
    display: none;
}
.select2-dropdown{
    border: 1px solid #d2d6de;
    border-radius: 0;
    font-size: 12px;
}
.select2-container--default .select2-results__option{
    color:#666666;
}
.select2-container--default .select2-results__option .option-input
{
    margin-left:16px;
}
.select2-container--default .select2-results__option .option-img
{
    width: 12px;
    position: absolute;
    top:9px;
}
.select2-container--default .select2-results__option--highlighted[aria-selected] {
    background-color: #3f9fe8;
    color: white;
}
.select2-container--default .select2-results__option[aria-selected=true]{
    background-color: #f7f7f7;
    color:#666666;
}

.select2-container--default .select2-selection--multiple .select2-selection__choice{
    color: #666666;
    background: #f7f7f7;
    border: 1px solid #dddddd;
    position: relative;
    padding-right: 20px;
}
.select2-container--default .select2-selection--multiple .select2-selection__choice__remove{
    cursor: pointer;
    position: absolute;
    right: .1em;
    top: 50%;
    margin-top: -9px;
    line-height: 17px;
    color: #333;
    font-size: 16px;
}
.select2-container--default .select2-selection--multiple .select2-selection__choice__remove:hover{
    color: #666;
}
.select2-container--default .select2-results__option[role='group'] .select2-results__group
{
    background-color: #eee;
    color: black;
    font-weight: 600;
}

#result-list > li.active .select2-container{
    border: 1px solid crimson;
}
#result-list > li.active .select-input{
    border: 1px solid crimson;
}
#result-list .mCSB_inside > .mCSB_container
{
    margin-right: 0;
}
#result-list .mCSB_scrollTools{
    width: 4px;
}
